#pragma once
#include "Position.h"
#include <vector>
#include <string>
using namespace std;
class Snake
{
public:
	int last_direction;

	vector < Position > body;

	Snake();
	void SetHead(Position ps);
	Position GetHead();
	void RemoveTail();
	void Show();
	int GetSize();
	void AddElement(Position ps);
	bool MoveStep(int direction);
	~Snake(void);
        void Receive(string str);
        string Send();

        string int2str(int n);
        int strToInt(const string &str);

};

